﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace LTHD_Web
{
    public partial class Searchmaps2 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            string ask = Request["ask"];
            int userid = int.Parse(Request.Cookies["userid"].Value);


            WS.Service1SoapClient diadiem = new WS.Service1SoapClient(); 

            List<WS.DiaDiemDTO> list = new List<WS.DiaDiemDTO>();

            list = diadiem.getAllDiaDiem2(ask);
            foreach(var n in list)
            {
                lb_content.Text += "<div class='one-result' >            <div class='user-picture'> <img src='Images/profile1.jpg' width='60px' />    </div>            <div class='search-info' >             <div class='info-title' > <a href='Discuss.aspx?id=" + n.Id + "'>" + n.Ten + "</div>       </a >     <div class='info-account' > By: " + n.Latitude + "</div>       <div class='info-account' > " + n.Longitude + "</div>     <div class='info-account' >  " + n.DiaChi + "</div>  <div class='info-account' id = 'like" + n.Id + "'> <a href='#' onclick='like(" + n.Id + " )'> Like </a ></div>                                   </div>                        </div>"; 
            }
            
        }
    }
}